import React from 'react';
import Money from './workPlace/Money';
import Getup from './workPlace/Getup';
// v6版本的使用
import { Routes, Route, Link, Navigate } from "react-router-dom";

const Workplace = () => {
    return (
        <div>
            <div className="topNav">
                <ul>
                    <li><Link to="/workPlace/Moeny">程序员加薪秘籍</Link></li>
                    <li><Link to="/workPlace/Getup">程序员早起攻略</Link></li>
                </ul>
            </div>
            <div className="videoContent">
                <div><h3>职场软技能</h3></div>
                <Routes>
                    <Route path="/*" element={<Navigate to={"/workPlace/Moeny"} />} />
                    <Route path="/Moeny/" element={<Money />} />
                    <Route path="/Getup/" element={<Getup />} />
                </Routes>
            </div>
        </div>
    )
}

export default Workplace;